package net.entelijan.config.impl2;

import java.awt.Component;

public abstract class ConfigUtil {

	private ConfigUtil() {
		super();
	}
	
	public static  String toStringView(Object view) {
		String re;
		if (view == null) {
			re = "null";
		} else if (view instanceof Component) {
			if (((Component) view).getName() != null) {
				re = view.getClass().getName() + " "
						+ ((Component) view).getName();
			} else {
				re = view.getClass().getName();
			}
		} else {
			re = "" + view;
		}
		return re;
	}


}
